package nl.infodation.emr.pricingservice.dao;

import java.io.Serializable;
import java.util.List;

import com.googlecode.genericdao.dao.jpa.GenericDAO;

public interface DAO<T, ID extends Serializable> extends GenericDAO<T, Serializable> {

	/**
	 * Save list of Entity
	 * @param entities
	 * @return
	 */
	Boolean save(List<T> entities);
	
	/**
	 * Remove list of Entity
	 * @param entities
	 * @return
	 */
	Boolean remove(List<T> entities);
	
	
	/**
	 * Remove by id
	 * @param id
	 * @return
	 */
	Boolean deleteById(ID id);
	
	/**
	 * Remove entity
	 * @param entity
	 * @return
	 */
	Boolean delete(T entity);
	
	/**
	 * Get all Entities by List of IDs
	 * @param ids
	 * @return
	 */
	List<T> findEntitiesByIDs(List<ID> ids);
	
	/**
	 * Find all Entity
	 * @return
	 */
	List<T> findAll();
	
	/**
	 * Get Entity by ID
	 * @param id
	 * @return
	 */
	T get(ID id);

}
